using System.Collections.Generic;
using UnityEngine;

public class UIPlatformSpecific : MonoBehaviour
{
	public bool everythingExcept;

	public RuntimePlatform platform;

	public List<RuntimePlatform> platforms = new List<RuntimePlatform>();

	public bool socialProviderSpecific;

	public ConfigBase.SocialProvider socialProvider;

	private void Awake()
	{
		bool flag = Application.platform == platform;
		foreach (RuntimePlatform platform in platforms)
		{
			flag = flag || Application.platform == platform;
		}
		if (socialProviderSpecific)
		{
			flag = flag && socialProvider == ConfigBase.instance.socialProvider;
		}
		if (everythingExcept)
		{
			flag = !flag;
		}
		base.gameObject.SetActive(flag);
	}
}
